/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package lolbuilder.fights;

import lolbuilder.build.Build;
import lolbuilder.params.Duo;

/**
 *
 * @author chocoboSan
 */
public class Versus implements Comparable {
    public Duo<Build,Build> matchup;

    public Versus(Duo<Build,Build> matchup) {
        this.matchup=matchup;
    }
    
    public int compareTo(Object o) {
        Versus other=(Versus) o;
        if (matchup.a.equals(other.matchup.a) && matchup.b.equals(other.matchup.b)) return 0;
        if (matchup.a.equals(other.matchup.b) && matchup.b.equals(other.matchup.a)) return 0;
        if (matchup.b.equals(other.matchup.a) && matchup.a.equals(other.matchup.b)) return 0;
        return -1;
    }
    
}
